package com.plus.controller;

import cn.hutool.core.collection.CollUtil;
import cn.hutool.core.date.DateUtil;
import cn.hutool.core.date.Month;
import cn.hutool.extra.servlet.ServletUtil;
import cn.hutool.extra.tokenizer.Result;
import cn.hutool.extra.tokenizer.TokenizerEngine;
import cn.hutool.extra.tokenizer.Word;
import cn.hutool.extra.tokenizer.engine.hanlp.HanLPEngine;
import com.plus.common.R;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.*;

import javax.servlet.http.HttpServletRequest;
import java.util.Iterator;

/**
 * @program: plus
 * @ClassName WelcomeController
 * @description:欢迎窗口
 * @author: AI
 * @create: 2023-10-31 15:10
 * @Version 1.0
 **/
@RestController
@RequestMapping("/api/welcome")
@Slf4j
public class WelcomeController {


    @GetMapping("/hello")
    public R Hello(HttpServletRequest request) {
        String clientIP = ServletUtil.getClientIP(request, null);
        return R.data(clientIP);
    }


}
